home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Business Assistant
/
Business Assistant.iso
/
acctg
/
db3ledge
/
addnames.prg
< prev
next >
Wrap
Text File
|
1986-01-12
|
1KB
|
78 lines
SET HEADING OFF
SET SAFETY OFF
***************(ADDNAMES.PRG)-JAY KENNEY
CLEAR
SET BELL OFF
SET TALK OFF
SET CONFIRM ON
SET EXACT ON
DO WHILE .T.
USE VEND
STORE 0 TO P
GO BOTT
STORE ACCT TO P
CLEAR
GO TOP
STORE 0 TO MACCT
STORE " " TO MNAME
@ 15,22 SAY 'Last entered #'
@ 15,37 SAY STR(P,3,0)
@ 20,22 SAY 'Do you want to enter an account? '
?
?
STORE ' ' TO OPTION
WAIT ' ? ' TO OPTION
IF OPTION<>'Y'
RETURN
ENDIF
IF OPTION='Y'
CLEAR
@ 6,25 SAY 'Enter account number ' GET MACCT PICTURE '999'
READ
LOCA FOR ACCT=MACCT
STORE NAME TO MNAME
IF .NOT. (EOF() .OR. BOF())
CLEAR
@ 6,20 SAY STR(MACCT,3,0)
@ 6,24 SAY 'is already in use as'
@ 6,45 say MNAME
@ 20,25 SAY 'Are you trying to confuse me? '
@ 23,37 SAY '?'
STORE 1 TO XX
DO WHILE XX<10
STORE XX+1 TO XX
ENDDO WHILE XX<10
SKIP
LOOP
ENDIF #<>0
CLEAR
APPEND BLANK
ENDIF
@ 3,33 SAY 'Account number'
@ 3,48 SAY MACCT
@ 5,25 SAY 'Vendor name ' GET NAME
@ 7,1 SAY 'Address ' GET ADDRESS
@ 9,1 SAY 'City ' GET CITY
@ 9,28 SAY 'State ' GET STATE
@ 9,40 SAY 'Zip ' GET ZIP
@ 11,1 SAY 'Phone ' GET PHONE
@ 13,1 SAY 'Notes ' GET NOTES
READ
REPLACE ACCT WITH MACCT
@ 17,1 CLEA
@ 17,33 SAY 'Is this correct? '
?
?
WAIT ' ? ' TO OPTION
IF OPTION<>'Y'
CLEA
@ 17,25 SAY 'Press Ctrl W when finished '
EDIT
ENDIF
CLEAR
ENDIF
ENDDO
SET BELL ON
SET EXACT OFF
RETURN (WHILE OPTION = 'N')